-
Notifications
You must be signed in to change notification settings - Fork 98
Logical operators #100
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Logical operators #100
Conversation
Please review and comment / commit if anything is wrong
Please review and comment / commit if anything is wrong
Please review and comment / commit if anything is wrong
Please review and comment / commit if anything is wrong
Please review and comment / commit if anything is wrong
Please review and comment / commit if anything is wrong
Please review and comment / commit if anything is wrong
Please review and comment / commit if anything is wrong
Please review and comment / commit if anything is wrong
Please review and comment / commit if anything is wrong
Please review and comment / commit if anything is wrong
Please review and comment / commit if anything is wrong
Please review and comment / commit if anything is wrong
Please review and comment / commit if anything is wrong
I translated line 7 as it was but in my opinion to keep it readable it would be better this way: نتیجه 0 || 1- برابر با 1- است، truthy Please review and comment / commit if anything is wrong
Please review and comment / commit if anything is wrong
Please review and comment / commit if anything is wrong
I translated line 7 as it was but in my opinion to keep it readable it would be better this way: نتیجه 0 || 1- برابر با 1- است، truthy Please review and comment / commit if anything is wrong
Translation is not done yet
I translated line 100 as it was but I think it would be better this way: این باعث چند استفاده جالب نسبت به یک "OR خالص و کلاسیک که تنها boolean قبول می کند" می شود. Please let me know what you think
Translation is not done yet
I translated line 100 as it was but I think it would be better this way: این باعث چند استفاده جالب نسبت به یک "OR خالص و کلاسیک که تنها boolean قبول می کند" می شود. Please let me know what you think and review and comment / commit if anything is wrong
@@ -1,4 +1,4 @@ | |||
The answer is `2`, that's the first truthy value. | |||
جواب 2 است، آن(2) اولین مقدار truthy است. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The 2
should be between backquotes:
جواب `2` است
and there is no need to mention it again:
آن(2)
|
||
## || (OR) | ||
## || (OR یا) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
There is no need for Persian translation.
alert( true || true ); // true درست | ||
alert( false || true ); // true درست | ||
alert( true || false ); // true درست | ||
alert( false || false ); // false اشتباه |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Use either true
or درست
, not both of them.
Use either false
or اشتباه
, not both of them.
alert( Boolean(null) ); // false | ||
``` | ||
|
||
The precedence of NOT `!` is the highest of all logical operators, so it always executes first, before `&&` or `||`. | ||
اولویت NOT `!` بالاترین اولویت بین عملگر های منطقی دارد، بنابراین همیشه اول اجرا می شود، قبل از `&&` یا `||`. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The sentence readability could be better:
عملگر NOT `!` بالاترین اولویت را بین عملگرهای منطقی دارد،
|
||
```js run | ||
let hour = 12; | ||
let isWeekend = true; | ||
|
||
if (hour < 10 || hour > 18 || isWeekend) { | ||
alert( 'The office is closed.' ); // it is the weekend | ||
alert( 'The office is closed.' ); // آخر هفته است |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The office is closed.
should also be translated.
Please make the requested changes. After it, add a comment "/done". |
All the mentioned problems are fixed.
Thank you for your review, @mahdyar |
/done |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thank you, @mahdiHashemi14!
Thank you 💖 I updated the Progress Issue #1 🎉 🎉 🎉 |
Please read the description of article.md and solution.md of task 8 "if question".
Please review and comment / commit if anything is wrong